how to find the transpose of a matrix in c